]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
environment: Mock more DesktopAppInfo methods
authorFlorian Müllner <fmuellner@gnome.org>
Sun, 10 Aug 2025 13:44:13 +0000 (15:44 +0200)
committerMarge Bot <marge-bot@gnome.org>
Sun, 10 Aug 2025 14:24:40 +0000 (14:24 +0000)
Commit ac113accf1e0927 didn't mock all DesktopAppInfo methods used by
gnome-shell, and https://gitlab.gnome.org/GNOME/glib/-/issues/3744
still hasn't been fixed.

Add the methods that are needed for the AppMenu, which hopefully are
all the remaining DesktopAppInfo methods we are using.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/8587
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3832>

js/ui/environment.js

index bbbdf1d31d1a9293cbae716e9e0e9e7001050723..a008a372c6c80926d0869a4dfceed80b8d8c8471 100644 (file)
@@ -347,9 +347,21 @@ if (!GioUnix.DesktopAppInfo.prototype.has_key) {
         return GioUnix.DesktopAppInfo.has_key(this, key);
     };
 
+    GioUnix.DesktopAppInfo.prototype.get_boolean = function (key) {
+        return GioUnix.DesktopAppInfo.get_boolean(this, key);
+    };
+
     GioUnix.DesktopAppInfo.prototype.get_categories = function () {
         return GioUnix.DesktopAppInfo.get_categories(this);
     };
+
+    GioUnix.DesktopAppInfo.prototype.list_actions = function () {
+        return GioUnix.DesktopAppInfo.list_actions(this);
+    };
+
+    GioUnix.DesktopAppInfo.prototype.get_action_name = function (name) {
+        return GioUnix.DesktopAppInfo.get_action_name(this, name);
+    };
 }
 
 const slowdownEnv = GLib.getenv('GNOME_SHELL_SLOWDOWN_FACTOR');